Skip to content

Add clear to the valid tag values (STF-190)#359

Merged
horgh merged 1 commit intomainfrom
greg/stf-190
Apr 23, 2026
Merged

Add clear to the valid tag values (STF-190)#359
horgh merged 1 commit intomainfrom
greg/stf-190

Conversation

@oschwald
Copy link
Copy Markdown
Member

Summary

  • Adds clear to the _tag validator in src/minfraud/validation.py so the
    Report Transaction API accepts the new tag.
  • Updates tests/test_validation.py to cover the new value.
  • Adds a HISTORY.rst bullet under the existing unreleased 3.3.0 entry.

The clear tag retracts a previously reported fraud report on a transaction
(restoring its label to "unknown", distinct from the positive not_fraud
signal). Backend support shipped in STF-15; this adds SDK support per STF-190.

Linear: https://linear.app/maxmind/issue/STF-190

Test plan

  • uv run pytest tests/test_validation.py — 62 passed
  • uv run ruff format / uv run ruff check — clean

🤖 Generated with Claude Code

Part of STF-190. The `clear` tag retracts a previously reported fraud report
tag on a transaction, restoring its label to "unknown" (distinct from the
positive `not_fraud` signal). The backend support was added in STF-15; this
exposes the new value through the client library.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request adds "clear" as a valid value for the "tag" parameter in the Report Transaction API. The changes include updating the validation logic in src/minfraud/validation.py, documenting the addition in HISTORY.rst, and expanding the test coverage in tests/test_validation.py. I have no feedback to provide.

@horgh horgh merged commit e9ed3be into main Apr 23, 2026
47 checks passed
@horgh horgh deleted the greg/stf-190 branch April 23, 2026 15:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants